package com.fun.feifun.modules.business.constant;


public enum ReturnStatusEnum {
    wait("等待充值/充值中","0"),
    paying("充值中","2"),
    success("充值成功","1"),
    fail("充值失败已退款","9"),
    ;

    private String title;
    private String value;


    ReturnStatusEnum(String title, String value){
        this.title=title;
        this.value=value;
    }

    // 根据key获取value的方法
    public static String getTitleByValue(String value){
        for (ReturnStatusEnum status : ReturnStatusEnum.values()) {
            if (status.getValue().equals(value)) {
                return status.getTitle();
            }
        }
        return ""; // 如果没有找到，返回null
    }

    public String getValue() {
        return value;
    }

    public String getTitle() {
        return title;
    }
}
